import Mock from 'mockjs'
const orderList = Mock.mock({
    "data|7": [{
        "苹果": "@integer(1000,5000)",
        "小米": "@integer(1000,5000)",
        "华为": "@integer(1000,5000)",
        "oppo": "@integer(1000,5000)",
        "vivo": "@integer(1000,5000)",
        "一加": "@integer(1000,5000)",
    }]
})

export default {
    getTableData: () => {
        return {
            code: 200,
            data: {
                tableData: [
                    {
                        name: "小米",
                        todayBuy: "1200",
                        monthBuy: "3000",
                        totalBuy: "45000",
                    },
                    {
                        name: "三星",
                        todayBuy: "1200",
                        monthBuy: "3000",
                        totalBuy: "45000",
                    },
                    {
                        name: "华为",
                        todayBuy: "1200",
                        monthBuy: "3000",
                        totalBuy: "45000",
                    },
                    {
                        name: "苹果",
                        todayBuy: "1200",
                        monthBuy: "3000",
                        totalBuy: "45000",
                    },
                ],

            }
        }
    },
    getCountData: () => {
        return {
            code: 200,
            data: {
                CountData: [
                    {
                        name: "今日支付订单",
                        value: 1234,
                        icon: "SuccessFilled",
                        color: "#2ec7c9",
                    },
                    {
                        name: "今日收藏订单",
                        value: 210,
                        icon: "StarFilled",
                        color: "#ffb980",
                    },
                    {
                        name: "今日未支付订单",
                        value: 587,
                        icon: "GoodsFilled",
                        color: "#5ab1ef",
                    },
                    {
                        name: "本月支付订单",
                        value: 12340,
                        icon: "SuccessFilled",
                        color: "#2ec7c9",
                    },
                    {
                        name: "本月收藏订单",
                        value: 2100,
                        icon: "StarFilled",
                        color: "#ffb980",
                    },
                    {
                        name: "本月未支付订单",
                        value: 5870,
                        icon: "GoodsFilled",
                        color: "#5ab1ef",
                    },
                ]
            }
        }
    },
    getEchartData: () => {
        return {
            code: 200,
            data: {
                orderData: {
                    "date": ['20201001', '20201002', '20201003', '20201004', '20201005', '20201006', '20201007'],
                    "data": orderList.data,
                },
                videoData: [
                    {
                        name: "小米",
                        value: 2999,
                    },
                    {
                        name: "苹果",
                        value: 5999,
                    },
                    {
                        name: "华为",
                        value: 3999,
                    },
                    {
                        name: "魅族",
                        value: 3200,
                    },
                    {
                        name: "三星",
                        value: 4500,
                    },
                    {
                        name: "oppo",
                        value: 1500,
                    },
                ],
                userData: [
                    {
                        date: '周一',
                        new: 5,
                        active: 200,
                    },
                    {
                        date: '周二',
                        new: 4,
                        active: 300,
                    },
                    {
                        date: '周三',
                        new: 9,
                        active: 100,
                    },
                    {
                        date: '周四',
                        new: 1,
                        active: 50,
                    },
                    {
                        date: '周五',
                        new: 1,
                        active: 50,
                    },
                    {
                        date: '周六',
                        new: 10,
                        active: 400,
                    },
                    {
                        date: '周日',
                        new: 10,
                        active: 500,
                    },
                ]
            }
        }
    },
}